using System;
using axCommerce.Data.Interface;

namespace axCommerce.Data
{
	public partial class CustomerInfo : ISimpleData
	{
		public Account AccountInfo { get; set; }

		private void FillAccountInfo()
		{
			if (AccountId.HasValue)
				AccountInfo = Account.Get(AccountId.Value);
		}

		public void Save()
		{
			CreatedDate = DateTime.Now;

			Insert();
		}

		public void UpdateInstance()
		{
			LastModifiedDate = DateTime.Now;

			Update();
		}

		public void MarkAsDeleted()
		{
			throw new System.NotImplementedException();
		}
	}
}

